<script setup lang="ts">
import dayjs from "dayjs";
import { ref } from "vue";
import { useInterval } from "@/framework/vue/hooks";

const getCurrentTime = () => dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss dddd");
const currentTime = ref(getCurrentTime());
useInterval(() => currentTime.value = getCurrentTime(), 1000);
</script>

<template>
<span>{{ currentTime }}</span>
</template>

<style scoped lang="less">

</style>
